﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace IBLL
{
   public interface IBaseService<T>
    {
       //新增
       bool Add(T entity);
       //删除
       bool Delete(T entity);
       //修改
       bool Update(T entity);
       //查询
       List<T> GetList(Func<T, bool> where);
       //分页查询
       List<T> GetListByPage<S>(Func<T, bool> where, Func<T, S> order, bool isAsc, int pageIndex, int pageSize, ref int count);
        List<T> GetListByPageIndexBy<S>(Expression<Func<T, bool>> where, Func<T, S> lambadaOrder, bool isAsc, int pageIndex, int pageSize, out int count);
    }
}
